home *** CD-ROM | disk | FTP | other *** search
/ Columbia Kermit / kermit.zip / newsgroups / misc.19970626-19970929 / 000182_news@newsmaster….columbia.edu _Sun Aug 17 11:06:04 1997.msg < prev    next >
Internet Message Format  |  2020-01-01  |  3KB

  1. Return-Path: <news@newsmaster.cc.columbia.edu>
  2. Received: from newsmaster.cc.columbia.edu (newsmaster.cc.columbia.edu [128.59.35.30])
  3.     by watsun.cc.columbia.edu (8.8.5/8.8.5) with ESMTP id LAA18975
  4.     for <kermit.misc@watsun.cc.columbia.edu>; Sun, 17 Aug 1997 11:06:03 -0400 (EDT)
  5. Received: (from news@localhost)
  6.     by newsmaster.cc.columbia.edu (8.8.5/8.8.5) id LAA20920
  7.     for kermit.misc@watsun; Sun, 17 Aug 1997 11:06:03 -0400 (EDT)
  8. Path: news.columbia.edu!watsun.cc.columbia.edu!fdc
  9. From: fdc@watsun.cc.columbia.edu (Frank da Cruz)
  10. Newsgroups: comp.protocols.kermit.misc
  11. Subject: Re: How do I start ckepage.ksc from command line
  12. Date: 17 Aug 1997 15:05:59 GMT
  13. Organization: Columbia University
  14. Lines: 65
  15. Message-ID: <5t740n$aas$1@apakabar.cc.columbia.edu>
  16. References: <871757417.12783@dejanews.com> <5t4uc7$8a0$1@apakabar.cc.columbia.edu> <33F6EBE4.31AECA6E@ttsg.com>
  17. NNTP-Posting-Host: watsun.cc.columbia.edu
  18. Xref: news.columbia.edu comp.protocols.kermit.misc:7488
  19.  
  20. In article <33F6EBE4.31AECA6E@ttsg.com>, TTSG  <ttsg@ttsg.com> wrote:
  21. : Frank da Cruz wrote:
  22. : > In article <871757417.12783@dejanews.com>,  <ttsg@ttsg.com> wrote:
  23. : > : I'm wondering now that I got the ckepage.ksc script working, how can I
  24. : > : start it from a command line and include all the parameters for apage?
  25. : > : I want to have a shell or perl script invoke it and just wait for the
  26. : > : reply if it was good or bad.
  27. : > :
  28. : > See pages 353, 467-468, and 513 of "Using C-Kermit".  Briefly, make the
  29. : > script into an "application" or "shebang" file, and read the command line
  30. : > arguments from the \&@[] array.
  31. : > 
  32. : > - Frank
  33. :
  34. : Thanks for the quick and helpful reply! Having the pages to go directly
  35. : to is great.  One word though, the script at:
  36. :   ftp://kermit.columbia.edu/kermit/f/ckepage.ksc
  37. : Is broken. It drove me nuts for almost 2 hours until I got enough
  38. : debugging in it.  What happened was I would get the ACK for the ESC-PG1,
  39. : then it would stay in the loop and keep claiming timeouts.  When I
  40. : looked at it, I realized it couldn't work.... How did it ever get out of
  41. : the for loop!?
  42. : THERE IS A "BREAK" MISSING!
  43. : for \%i 1 3 1 {            ; Send <ESC>PG1, get <ACK>
  44. :         msl 500
  45. :         out \{27}PG1\13
  46. :         min 3 {\6\13} {\21\13} {\27\4\13}
  47. :         switch \v(minput) {
  48. :           :0, continue                ; Timeout
  49. :           :1, break                   ; <ACK>
  50. :           :2, continue                ; <NAK>
  51. :           :3, stop 1 Forced disconnect ; Fatal error
  52. :         }
  53. :     }
  54. : SHOULD BE :
  55. : for \%i 1 3 1 {            ; Send <ESC>PG1, get <ACK>
  56. :         msl 500
  57. :         out \{27}PG1\13
  58. :         min 3 {\6\13} {\21\13} {\27\4\13}
  59. :         switch \v(minput) {
  60. :           :0, continue                ; Timeout
  61. :           :1, break                   ; <ACK>
  62. :           :2, continue                ; <NAK>
  63. :           :3, stop 1 Forced disconnect ; Fatal error
  64. :         }
  65. :         break
  66. :     }
  67. You're right.  I stuck this section of code into a loop a couple weeks
  68. ago when I discovered a paging service that needed it (contrary to the
  69. wording of the TAP specification) -- it lost characters galore and so
  70. tended to miss the <ESC>PG1 reply, and so would need to see it again
  71. (and again).  Tests worked, of course :-)
  72.  
  73. Sorry for the confusion, updated script in the normal place:
  74.  
  75.   ftp://kermit.columbia.edu/kermit/f/ckepage.ksc
  76.  
  77. - Frank